#include <stdio.h>
#include <stdlib.h>
#include <string.h>

int main()
{	
	char dir0[256] = "/home/ftp/user";
	char dir[256];
	char cmd[256];
	for(int i = 0; i < 100; i ++) 
	{
		snprintf(dir, sizeof(dir), "%s%d", dir0, i + 1);
		snprintf(cmd, sizeof(cmd), "mkdir -p %s", dir);
		system(cmd);
		snprintf(cmd, sizeof(cmd), "chmod 777 %s", dir);
		system(cmd);
	}

	return 0; 
}
